
Partial Class MasterPage
    Inherits System.Web.UI.MasterPage

    ''' <summary>
    ''' Sign out from the web application
    ''' </summary>
    ''' <param name="sender"></param>
    ''' <param name="e"></param>
    ''' <remarks></remarks>
    Protected Sub LinkButton1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles LinkButton1.Click
        FormsAuthentication.SignOut()
        Response.Redirect("Logon.aspx", True)
    End Sub

    ''' <summary>
    ''' If the user is logged in display the hidden menu
    ''' </summary>
    ''' <param name="sender"></param>
    ''' <param name="e"></param>
    ''' <remarks></remarks>
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        if ( HttpContext.Current.User.Identity.IsAuthenticated )
            Panel3.Visible = True
        End If
    End Sub
End Class

